function hostobj(hst) {

  this.gw=false;
  this.mac=hst.getAttribute("MacAddr");
  if(hst.getAttribute("MacManifacturer")!=null) { 
    this.macm=hst.getAttribute("MacManifacturer");
  }

  for(i=0; i<hst.getElementsByTagName("IPAddr").length; i++) {
    
    if(i==0) { this.ip=hst.getElementsByTagName("IPAddr")[0].childNodes[0].nodeValue; }
    else {
      if(!this.otherips) { this.otherips = []; }
      this.otherips.push(hst.getElementsByTagName("IPAddr")[i].childNodes[0].nodeValue);
    }
  }


  if(hst.getAttribute("IsInNetmask")!=null) { 
    if(hst.getAttribute("IsInNetmask")=="True") this.isInNetmask=true;
    else this.isInNetmask=false;
  }

  this.summary=[];
  this.services=[];
  this.services_port=[];


  if(hst.getElementsByTagName("Dot11Info").length>0) {
    this.essid=hst.getElementsByTagName("Dot11Info")[0].getElementsByTagName("Info")[0].childNodes[0].nodeValue;
    this.ap=true;
    this.summary.push("access point");
    this.image="images/ap.png";

  }
  else if(hst.getAttribute("Gw")=="true") { 
    this.gw=true;
    this.image="images/gw.png";
    this.summary.push("gateway");
  }
  else if(hst.getAttribute("Me")=="true") { 
    this.image="images/home.png";
    this.summary.push("local host");
  }
  else {
    this.image="images/host.png";
  }
  

  if(hst.getElementsByTagName("OperatingSystem").length>0) {
    this.os=hst.getElementsByTagName("OperatingSystem")[0].getElementsByTagName("Name")[0].childNodes[0].nodeValue;
    this.osver = hst.getElementsByTagName("OperatingSystem")[0].getElementsByTagName("Version")[0].childNodes[0].nodeValue;
  }


  for(i=0; i<hst.getElementsByTagName("Service").length; i++) {
    this.services.push(hst.getElementsByTagName("Service")[i].getElementsByTagName("Name")[0].childNodes[0].nodeValue);
    this.services_port.push(hst.getElementsByTagName("Service")[i].getElementsByTagName("Port")[0].childNodes[0].nodeValue + "/" + hst.getElementsByTagName("Service")[i].getElementsByTagName("Proto")[0].childNodes[0].nodeValue.toLowerCase());
  }



}
